#include "stdafx.h"

#pragma once

static const int MaxErrMsgLen = 1024;
class HookEngineException: std::exception
{
public:
	HookEngineException();
};WS_BORDER

class FatalException: HookEngineException
{
public:
	FatalException(const char * pErrMsg);
};

class NullPointerException: HookEngineException
{
public:
	NullPointerException(const char * pErrMsg);
};

class OutOfMemoryException: HookEngineException
{
public:
	OutOfMemoryException(const char * pErrMsg);
};


class ArgumentException: HookEngineException
{
public:
	ArgumentException(const char * pErrMsg);
};


class AllocationFailureException: HookEngineException
{
private:
	char m_szErrMsg[MaxErrMsgLen];
public:
	AllocationFailureException(const char * pErrMsg);

	AllocationFailureException(const char * pErrMsg, int errorCode);
};

class Win32APIFailureException: HookEngineException
{
	char m_szErrMsg[MaxErrMsgLen];
public:
	Win32APIFailureException(const char * pErrMsg);
	Win32APIFailureException(const char * pErrMsg, int errorCode);
};